﻿using Polaris.Domain.Model.Dto.Sys_Dictionary.Request;
using Polaris.Domain.Model.Dto.Sys_Dictionary.Response;
using Polaris.Domain.Model.Dto.Sys_Dictionary_Item.Request;
using Polaris.Domain.Model.Dto.Sys_Dictionary_Item.Response;
using Polaris.Domain.Model.Entity.Base;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Polaris.Domain.Interfaces.Admin
{
    public interface ISys_Dictionary_Item
    {
        /// <summary>
        /// 创建字典项
        /// </summary>
        /// <param name="create"></param>
        /// <returns></returns>
        Task CreateDictionaryItem(CreateDictionaryItemRequest create, Guid? userId);

        /// <summary>
        /// 修改字典项
        /// </summary>
        /// <param name="update"></param>
        /// <returns></returns>
        Task UpdateDictionaryItem(UpdateDictionaryItemRequest update, Guid? userId);

        /// <summary>
        /// 删除字典项
        /// </summary>
        /// <param name="id"></param>
        /// <param name="userId"></param>
        /// <returns></returns>
        Task DeleteDictionaryItem(string id,Guid? userId);

        /// <summary>
        /// 根据id获取字典项信息
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        Task<DictionaryItemInfoResponse> GetDictionaryItemById(string id);

        /// <summary>
        /// 根据字典值获取字典项
        /// </summary>
        /// <param name="code"></param>
        /// <returns></returns>
        Task<List<D_ItemOptionResponse>> GetDictionaryItemByCode(string code);

        /// <summary>
        /// 根据字典id获取字典项列表
        /// </summary>
        /// <param name="search"></param>
        /// <returns></returns>
        Task<PaginationInfo<DictionaryItemInfoResponse>> GetDictionaryItemListByDid(SearchDictionaryItemRequest search);

    }
}
